import request from '@/config/axios'

export function getItemCascadeClassificationApi() {
	return request.post<CascadeClassificationVo[]>({
		url: '/game/g-item/readOnly/getItemCascadeClassification'
	})
}

export function getBuildingDetailByIdApi(itemId: number) {
	return request.get<ItemDetailVo>({
		url: '/game/g-item/readOnly/getItemDetailById/' + itemId
	})
}

export function saveItemApi(data: GItem) {
	return request.post({
		url: '/game/g-item/saveItem',
		data
	})
}

export function deleteItemApi(id: number) {
	return request.delete({
		url: '/game/g-item/deleteItem/' + id
	})
}
